:root {
    --primary-color: #8a2be2;
    --secondary-color: #9370db;
    --accent-color: #da70d6;
    --background-color: #0f0f1a;
    --card-color: #1a1a2e;
    --text-color: #e6e6ff;
    --success-color: #00fa9a;
    --warning-color: #ff8c00;
    --danger-color: #ff416c;
    --info-color: #4cc9f0;
    --dark-purple: #2d0f41;
    --neon-pink: #ff00ff;
    --neon-blue: #00ffff;
    --gold: #ffd700;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: linear-gradient(135deg, var(--background-color), #1a1a2e, #16213e);
    color: var(--text-color);
    min-height: 100vh;
    padding: 20px;
    background-attachment: fixed;
    position: relative;
    overflow-x: hidden;
}

body::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: 
        radial-gradient(circle at 10% 20%, rgba(138, 43, 226, 0.1) 0%, transparent 20%),
        radial-gradient(circle at 90% 80%, rgba(218, 112, 214, 0.1) 0%, transparent 20%),
        url('/img/myfz.jpeg') no-repeat center center;
    background-size: cover;
    opacity: 0.25;
    z-index: -1;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
}

/* Header 样式 */
header {
    text-align: center;
    padding: 30px 0;
    margin-bottom: 30px;
    background: linear-gradient(90deg, var(--primary-color), var(--accent-color));
    border-radius: 15px;
    box-shadow: 
        0 10px 30px rgba(138, 43, 226, 0.3),
        0 0 20px rgba(218, 112, 214, 0.5);
    position: relative;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

header::before {
    content: "";
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255,255,255,0.1) 0%, transparent 70%);
    transform: rotate(30deg);
}

header h1 {
    font-size: 2.8rem;
    margin-bottom: 10px;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
    position: relative;
    background: linear-gradient(to right, #ffd700, #ffffff);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    text-fill-color: transparent;
    animation: shine 3s infinite;
}

@keyframes shine {
    0% { background-position: -200%; }
    100% { background-position: 200%; }
}

header p {
    font-size: 1.2rem;
    opacity: 0.9;
}

/* 卡片样式 */
.card {
    background: var(--card-color);
    border-radius: 15px;
    padding: 30px;
    margin-bottom: 30px;
    box-shadow: 
        0 10px 30px rgba(0, 0, 0, 0.3),
        0 0 0 1px rgba(138, 43, 226, 0.3);
    border: 1px solid rgba(138, 43, 226, 0.3);
    position: relative;
    overflow: hidden;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.card::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: linear-gradient(90deg, var(--primary-color), var(--accent-color));
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: 
        0 15px 35px rgba(0, 0, 0, 0.4),
        0 0 25px rgba(138, 43, 226, 0.5);
}

.card h2 {
    color: var(--accent-color);
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 2px solid rgba(218, 112, 214, 0.3);
    position: relative;
}

.card h2::after {
    content: "";
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 100px;
    height: 2px;
    background: linear-gradient(90deg, var(--accent-color), transparent);
}

/* 表单样式 */
.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: bold;
    font-size: 1.1rem;
    color: var(--info-color);
}

.form-group input, 
.form-group select {
    width: 100%;
    padding: 12px;
    border: 2px solid var(--secondary-color);
    border-radius: 8px;
    background: rgba(26, 26, 46, 0.7);
    color: var(--text-color);
    font-size: 1rem;
    transition: all 0.3s ease;
}

.form-group input:focus, 
.form-group select:focus {
    outline: none;
    border-color: var(--accent-color);
    box-shadow: 0 0 15px rgba(218, 112, 214, 0.5);
    background: rgba(138, 43, 226, 0.2);
}

.form-group select option {
    background: var(--card-color);
    color: var(--text-color);
}

/* 角色信息区域 */
.character-section {
    background: rgba(138, 43, 226, 0.1);
    border: 1px solid var(--secondary-color);
    padding: 20px;
    margin: 25px 0;
    border-radius: 10px;
    position: relative;
}

.character-section::before {
    content: "🧙";
    position: absolute;
    top: -15px;
    left: 15px;
    background: var(--card-color);
    padding: 0 10px;
    font-size: 1.5rem;
}

.character-item {
    background: rgba(26, 26, 46, 0.7);
    border: 1px dashed var(--accent-color);
    padding: 20px;
    margin-bottom: 20px;
    border-radius: 10px;
    position: relative;
    transition: all 0.3s ease;
}

.character-item:hover {
    background: rgba(138, 43, 226, 0.2);
    transform: translateX(5px);
}

.character-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 1px solid var(--secondary-color);
}

.character-header h3 {
    color: var(--gold);
    text-shadow: 0 0 10px rgba(255, 215, 0, 0.5);
}

/* 按钮样式 */
.btn {
    padding: 12px 25px;
    background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
    color: white;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-size: 1rem;
    font-weight: bold;
    transition: all 0.3s ease;
    box-shadow: 0 4px 10px rgba(138, 43, 226, 0.3);
    position: relative;
    overflow: hidden;
}

.btn::before {
    content: "";
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: 0.5s;
}

.btn:hover::before {
    left: 100%;
}

.btn:hover {
    transform: translateY(-3px);
    box-shadow: 
        0 6px 15px rgba(138, 43, 226, 0.5),
        0 0 20px rgba(138, 43, 226, 0.3);
}

.btn:active {
    transform: translateY(1px);
}

.btn-danger {
    background: linear-gradient(90deg, #ff416c, #ff4b2b);
    box-shadow: 0 4px 10px rgba(255, 65, 108, 0.3);
}

.btn-success {
    background: linear-gradient(90deg, #00b09b, #96c93d);
    box-shadow: 0 4px 10px rgba(0, 176, 155, 0.3);
}

.btn-info {
    background: linear-gradient(90deg, var(--info-color), #4361ee);
    box-shadow: 0 4px 10px rgba(76, 201, 240, 0.3);
}

/* 操作按钮区域 */
.action-buttons {
    display: flex;
    gap: 15px;
    margin-top: 30px;
    flex-wrap: wrap;
}

/* 链接样式 */
.back-link, .action-link {
    display: inline-block;
    color: var(--accent-color);
    text-decoration: none;
    font-weight: bold;
    transition: all 0.3s ease;
    padding: 5px 10px;
    border-radius: 5px;
}

.back-link:hover, .action-link:hover {
    color: var(--info-color);
    background: rgba(218, 112, 214, 0.1);
    text-decoration: none;
    transform: scale(1.05);
}

.action-link {
    cursor: pointer;
    margin: 0 5px;
}

/* 搜索区域 */
.search-section {
    background: var(--card-color);
    padding: 25px;
    border-radius: 15px;
    margin-bottom: 30px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(138, 43, 226, 0.3);
}

.search-section .form-group {
    display: inline-block;
    margin-right: 15px;
    margin-bottom: 15px;
}

.search-section .form-group label {
    margin-right: 10px;
    font-weight: bold;
    font-size: 1.1rem;
}

/* 表格样式 */
.table-container {
    overflow-x: auto;
    background: var(--card-color);
    border-radius: 15px;
    padding: 20px;
    margin-bottom: 30px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(138, 43, 226, 0.3);
}

table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 20px;
}

th, td {
    border: 1px solid #444;
    padding: 15px;
    text-align: left;
}

th {
    background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
    color: white;
    font-weight: bold;
    position: relative;
}

th::after {
    content: "";
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 2px;
    background: var(--gold);
}

tr:nth-child(even) {
    background: rgba(138, 43, 226, 0.1);
}

tr:hover {
    background: rgba(138, 43, 226, 0.2);
}

/* 状态样式 */
.status-completed {
    color: var(--success-color);
    font-weight: bold;
    position: relative;
    padding-left: 20px;
}

.status-completed::before {
    content: "✓";
    position: absolute;
    left: 0;
    color: var(--gold);
}

.status-not-completed {
    color: var(--danger-color);
    font-weight: bold;
    position: relative;
    padding-left: 20px;
}

.status-not-completed::before {
    content: "✗";
    position: absolute;
    left: 0;
    color: var(--warning-color);
}

/* 角色详情网格 */
.character-details {
    margin: 15px 0;
    padding: 15px;
    background: rgba(26, 26, 46, 0.7);
    border-left: 4px solid var(--accent-color);
    border-radius: 0 8px 8px 0;
}

.character-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 15px;
    margin-top: 10px;
}

.character-card {
    background: linear-gradient(135deg, rgba(138, 43, 226, 0.2), rgba(26, 26, 46, 0.7));
    border: 1px solid var(--accent-color);
    border-radius: 8px;
    padding: 15px;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.character-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 15px rgba(218, 112, 214, 0.3);
    border-color: var(--gold);
}

.character-card::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background: linear-gradient(90deg, var(--primary-color), var(--accent-color));
}

.character-name {
    font-size: 1.3rem;
    font-weight: bold;
    color: var(--gold);
    margin-bottom: 10px;
    text-shadow: 0 0 8px rgba(255, 215, 0, 0.5);
}

.character-info {
    margin: 8px 0;
    display: flex;
    justify-content: space-between;
}

.character-info strong {
    color: var(--info-color);
}

/* 分页样式 */
.pagination {
    display: flex;
    justify-content: center;
    margin-top: 30px;
    gap: 10px;
    flex-wrap: wrap;
}

.pagination button {
    padding: 12px 20px;
    background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
    color: white;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-size: 1rem;
    font-weight: bold;
    transition: all 0.3s ease;
    box-shadow: 0 4px 10px rgba(138, 43, 226, 0.3);
}

.pagination button:disabled {
    background: #555;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

.pagination button:hover:not(:disabled) {
    transform: translateY(-3px);
    box-shadow: 0 6px 15px rgba(138, 43, 226, 0.5);
}

/* 总金额显示 */
.total-amount {
    font-size: 2rem;
    font-weight: bold;
    text-align: center;
    padding: 30px;
    background: linear-gradient(90deg, var(--card-color), #2d2d4d);
    border-radius: 15px;
    margin-bottom: 30px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
    border: 1px solid var(--secondary-color);
    position: relative;
    overflow: hidden;
}

.total-amount::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 5px;
    background: linear-gradient(90deg, var(--primary-color), var(--accent-color), var(--info-color));
}

.total-amount span {
    color: var(--success-color);
    font-size: 2.5rem;
    text-shadow: 0 0 10px rgba(0, 250, 154, 0.5);
}

/* 导航按钮 */
.nav-buttons {
    display: flex;
    justify-content: center;
    gap: 20px;
    flex-wrap: wrap;
    margin-bottom: 30px;
}

.nav-btn {
    padding: 15px 30px;
    background: linear-gradient(90deg, var(--primary-color), var(--accent-color));
    color: white;
    border: none;
    border-radius: 10px;
    cursor: pointer;
    font-size: 1.1rem;
    font-weight: bold;
    text-decoration: none;
    transition: all 0.3s ease;
    box-shadow: 0 5px 15px rgba(138, 43, 226, 0.3);
    position: relative;
    overflow: hidden;
}

.nav-btn:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 20px rgba(138, 43, 226, 0.5);
}

.nav-btn::before {
    content: "";
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: 0.5s;
}

.nav-btn:hover::before {
    left: 100%;
}

/* 页脚 */
footer {
    text-align: center;
    padding: 20px;
    margin-top: 30px;
    color: var(--secondary-color);
    font-size: 0.9rem;
    position: relative;
}

footer::before {
    content: "";
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 50%;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--secondary-color), transparent);
}

/* 响应式设计 */
@media (max-width: 768px) {
    body {
        padding: 10px;
    }
    
    header h1 {
        font-size: 2rem;
    }
    
    .card {
        padding: 20px;
    }
    
    .action-buttons {
        flex-direction: column;
    }
    
    .btn, .nav-btn {
        width: 100%;
        text-align: center;
    }
    
    .search-section .form-group {
        display: block;
        margin-bottom: 15px;
    }
    
    .pagination {
        flex-direction: column;
        align-items: center;
    }
    
    .pagination button {
        width: 80%;
        margin-bottom: 10px;
    }
    
    .character-grid {
        grid-template-columns: 1fr;
    }
    
    .nav-buttons {
        flex-direction: column;
        align-items: center;
    }
    
    .total-amount {
        font-size: 1.5rem;
    }
    
    .total-amount span {
        font-size: 2rem;
    }
}

/* 动画效果 */
@keyframes pulse {
    0% { box-shadow: 0 0 0 0 rgba(138, 43, 226, 0.4); }
    70% { box-shadow: 0 0 0 10px rgba(138, 43, 226, 0); }
    100% { box-shadow: 0 0 0 0 rgba(138, 43, 226, 0); }
}

.pulse {
    animation: pulse 2s infinite;
}

/* 控制面板 */
.header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    padding: 20px;
    background: var(--card-color);
    border-radius: 10px;
    margin-bottom: 30px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(138, 43, 226, 0.3);
}

.rate-section {
    display: flex;
    align-items: center;
    gap: 15px;
    flex-wrap: wrap;
}

.rate-section label {
    font-size: 1.2rem;
    font-weight: bold;
    color: var(--info-color);
}

.rate-input {
    width: 100px;
    padding: 10px;
    border: 2px solid var(--secondary-color);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.1);
    color: var(--text-color);
    font-size: 1rem;
}

.update-btn {
    padding: 10px 20px;
    background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
    color: white;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-size: 1rem;
    font-weight: bold;
    transition: all 0.3s ease;
    box-shadow: 0 4px 10px rgba(138, 43, 226, 0.3);
}

.update-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 15px rgba(138, 43, 226, 0.5);
}